import {moduleName} from "./a_moduleInfo";
import CrudCommon from "@/api/util/crudCommonController";

class CJS extends CrudCommon {
  constructor() {
    super({moduleName: moduleName, entityName: 'tichuConfig'}); //  调用父类的 constructor(x, y)
  }

  /**
   * 传入查询参数，如果之前没有，自动以二级的三个职级创建新数据，并通过ifNew==1 判断，并提示用户
   * @param years
   * @param rootDeptCode
   * @param sourceType
   */
  initEnt(years, rootDeptCode, sourceType) {
    return this.doRequest({
      url: this.baseUrl + '/initEnt',
      method: 'get',
      params: {
        years: years,
        rootDeptCode: rootDeptCode,
        useSourceType: sourceType
      }
    })
  }
}

export default new CJS();
